chore(make): add CI-faithful verify targets to Makefile#19
Merged
Conversation
The existing `clippy`, `test`, `ci`, and `pre-commit` targets all run weaker checks than `.github/workflows/ci.yml` does (default features, `-W warnings` instead of `-D warnings`, debug-mode tests). That gap let clippy and build regressions slip into PRs and only surface on the self-hosted macOS runner ~15 minutes later — which we hit three times in a row while shipping the gpt-oss bf16 fix and the clippy 1.95 sweep. This adds a parallel set of `verify*` targets that mirror the CI job step-for-step: - `verify-fmt` — cargo fmt --all -- --check - `verify-clippy` — cargo clippy --all-targets --features metal,accelerate -- -D warnings - `verify-test` — cargo test --release --features metal,accelerate - `verify` — runs the three above; recommended before push - `verify-clean` — cargo clean + verify, for when clippy's per-crate cache may be hiding a regression in shared mlxcel-core code The header comment block explains exactly why these differ from the existing looser targets, so future readers don't accidentally collapse the two sets back together. The looser `clippy` / `test` / `ci` / `pre-commit` targets are left untouched — they remain useful for fast inner-loop iteration where CI parity isn't needed.
This was referenced May 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a
verify*family of Makefile targets that reproduce the GitHub Actionsclippy + test (macOS ARM64)job exactly. The existingclippy/test/ci/pre-committargets are weaker than CI in three ways that have repeatedly bitten us:--features metal,accelerate, large gated regions ofmlxcel-core(parts ofcache/turbo/quant, the attention-dispatch helpers, the metal/accelerate-only branches ingenerate.rs) aren't even type-checked locally.-W warningsinstead of-D warnings— local clippy silently passes on regressions that CI will reject.cargo test --release, which exercises different optimisation paths.This gap cost us three CI rounds (~45 min wasted on the self-hosted runner) while shipping the gpt-oss bf16 fix (#17) and the clippy 1.95 sweep (#18). The new targets close it.
New targets
verify-fmtcargo fmt --all -- --checkverify-clippycargo clippy --all-targets --features metal,accelerate -- -D warningsverify-testcargo test --release --features metal,accelerateverifyverify-cleancargo clean+verify(use when clippy's per-crate cache may be hiding a regression after editing shared mlxcel-core code)Not changed
The existing looser targets (
fmt-check,clippy,test,ci,pre-commit) are preserved — they remain useful for fast inner-loop iteration where strict CI parity isn't needed. The header comment block above theverify*block explains the distinction so the two sets don't accidentally get collapsed later.Test plan
make verify-fmtsucceeds on a clean tree.github/workflows/ci.ymllines 77, 102, 104make verifyend-to-end in the next "before push" cycle